<template>
  <div>
    <van-cell-group v-for="item in pocketList" :key="item.id">
      <van-card
        :price="item.price + '.00'"
        :desc="item.introduce"
        :title="item.name"
        thumb="https://img01.yzcdn.cn/vant/ipad.jpeg"
      >
        <template #num>
          <van-button type="default" class="btn" @click="gotoSimilarGoods()"
            >找相似</van-button
          >
        </template>
      </van-card>
    </van-cell-group>
  </div>
</template>
<script>
export default {
  name: "YiLIngCard",

  data() {
    return {};
  },
  props: ["pocketList"],
  mounted() {},

  methods: {
    // 找相似页面
    gotoSimilarGoods() {
      this.$router.push("/similarGoods");
    },
  },
};
</script>

<style lang="less" scoped>
// 卡片背景颜色
.van-card {
  background-color: #fff;
}
// 找相似按钮
.btn {
  border-radius: 10px;
  color: #bebebe;
  border-color: #bebebe;
  height: 30px;
}

// 卡片价格颜色
.van-card__price {
  color: #e7637a;
}
.van-card__desc {
  color: #dfdfdf;
  line-height: 30px;
}
.van-card__title {
  line-height: 25px;
}
</style>